<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/static/taglibs.jsp"%>

<html>
<head>
    <meta charset="utf-8">
    <title>用户登录</title>
    <script type="text/javascript" src="${ctx }/layui/layui.js"></script>
    <link rel="stylesheet" href="${ctx }/layui/css/layui.css">
    
    <!-- 预加载各种模块 -->
    <script type="text/javascript">
        layui.use(['layer', 'form', 'element'], function(){
    	  var layer = layui.layer
    	  ,form = layui.form
    	  ,element = layui.element
    	  
//     	  form.on('submit(*)', function(data){
//     		  alert(11111);
//               console.log(data.elem) //被执行事件的元素DOM对象，一般为button对象
//               console.log(data.form) //被执行提交的form对象，一般在存在form标签时才会返回
//               console.log(data.field) //当前容器的全部表单字段，名值对形式：{name: value}
//           });
    	});
    </script>
    
</head>

<body>
	<form class="layui-form" id="form" action="${ctx }/login.html" method="post">
		<div class="layui-form-item">
			<label class="layui-form-label">用户名:</label>
			<div class="layui-input-block">
			    <input type="text" id="userName" name="userName" style="width: 200px" placeholder="请输入用户名" class="layui-input">
			</div>
		</div>
		
		<div class="layui-form-item">
			<label class="layui-form-label">密码:</label>
			<div class="layui-input-block">
			    <input type="text" id="password" name="password" style="width: 200px" placeholder="请输入密码" class="layui-input">
			</div>
		</div>
		
		<button class="layui-btn layui-btn-radius" style="margin-left:110px;">登录</button>
		<button class="layui-btn layui-btn-radius" style="margin-left:59px;">注册</button>
	</form>
</body>
</html>
